import 'package:json_annotation/json_annotation.dart';

part 'data.g.dart';

@JsonSerializable()
class UserData {
  String userId;
  String code;
  String password;
  String userName;
  String headPic;
  String idCardNo;
  int gender;
  String summary;
  String jobTitle;
  String validateCode;
  int periodId;
  int subjectId;
  int gradeId;
  int schoolId;
  String schoolName;
  int guideFlag;
  int bookId;
  String bookName;
  String bookType;
  String userType;
  int servertime;
  String appVerstion;

  UserData(
      {this.userId,
      this.code,
      this.userName,
      this.password,
      this.headPic,
      this.idCardNo,
      this.gender,
      this.summary,
      this.jobTitle,
      this.validateCode,
      this.periodId,
      this.subjectId,
      this.gradeId,
      this.schoolId,
      this.schoolName,
      this.guideFlag,
      this.bookId,
      this.bookName,
      this.bookType,
      this.userType,
      this.servertime,
      this.appVerstion});

//反序列化
  factory UserData.fromJson(Map<String, dynamic> json) => _$UserDataFromJson(json);
//序列化
  Map<String, dynamic> toJson() => _$UserDataToJson(this);

}

